<!DOCTYPE html>

<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<link rel="stylesheet" type="text/css" href="style.css">
<title>Captive</title>
<script type="text/javascript" src="jquery-1.9.1.min.js"></script>


<script>

	var init = 5;
	
	$(document).ready(
		function() {
			document.getElementById("dialog").style.display="inherit";
			document.getElementById("background").style.display="inherit";
			document.getElementById("peopleimage").src="images/stephen.png";
			document.getElementById("dialog").innerHTML = "Stephen says: <br/>Why should I trust you? Even your son Jimmy doesn't trust you!";
			$("#dialog").click(dialog1);
		}
	);
	
	function dialog1()
	{
		$("#dialog").unbind('click');
		document.getElementById("peopleimage").src="images/blank.png";
		document.getElementById("dialog").innerHTML = "I say: <br/><div onclick=\"dialog2()\">1. Why don't you trust me?</div><div onclick=\"dialog3()\">2. Why doesn't Jimmy trust me?</div>";
		setTimeout(bind_click, 1000);
		function bind_click(){
			$("#dialog").click(dialog2);
		}
	}
	
	function dialog2()
	{
		$("#dialog").unbind('click');
		document.getElementById("peopleimage").src="images/stephen.png";
		document.getElementById("dialog").innerHTML = "Stephen says mockingly: <br/>Becuase you betrayed my father!";
		setTimeout(bind_click, 1000);
		function bind_click(){
			$("#dialog").click(to31);
		}
	}
	
	function dialog3()
	{
		$("#dialog").unbind('click');
		document.getElementById("peopleimage").src="images/stephen.png";
		document.getElementById("dialog").innerHTML = "Stephen says mockingly: <br/>Why don't you ask your son?";
		setTimeout(bind_click, 1000);
		function bind_click(){
			$("#dialog").click(to33);
		}
	}
	
	
	function to31()
	{
			window.location = "scene3-1.php";
	}
	
	function to33()
	{
			window.location = "scene3-3.php";
	}
	
	
</script>



</head>

<body>


<div id="container">
	<div id="background"><img src="images/harbor.jpg" /></div>
	<div id="dialog">
	</div>
	<div id="people"><img id="peopleimage" src=""></div>
</div>




</body>
</html>